home *** CD-ROM | disk | FTP | other *** search
/ PC World Komputer 2010 April / PCWorld0410.iso / hity wydania / Ubuntu 9.10 PL / karmelkowy-koliberek-desktop-9.10-i386-PL.iso / casper / filesystem.squashfs / usr / include / asm-generic / statfs.h < prev    next >
C/C++ Source or Header  |  2009-10-16  |  2KB  |  81 lines

  1. #ifndef _GENERIC_STATFS_H
  2. #define _GENERIC_STATFS_H
  3.  
  4. #include <linux/types.h>
  5.  
  6.  
  7. /*
  8.  * Most 64-bit platforms use 'long', while most 32-bit platforms use '__u32'.
  9.  * Yes, they differ in signedness as well as size.
  10.  * Special cases can override it for themselves -- except for S390x, which
  11.  * is just a little too special for us. And MIPS, which I'm not touching
  12.  * with a 10' pole.
  13.  */
  14. #ifndef __statfs_word
  15. #if BITS_PER_LONG == 64
  16. #define __statfs_word long
  17. #else
  18. #define __statfs_word __u32
  19. #endif
  20. #endif
  21.  
  22. struct statfs {
  23.     __statfs_word f_type;
  24.     __statfs_word f_bsize;
  25.     __statfs_word f_blocks;
  26.     __statfs_word f_bfree;
  27.     __statfs_word f_bavail;
  28.     __statfs_word f_files;
  29.     __statfs_word f_ffree;
  30.     __kernel_fsid_t f_fsid;
  31.     __statfs_word f_namelen;
  32.     __statfs_word f_frsize;
  33.     __statfs_word f_spare[5];
  34. };
  35.  
  36. /*
  37.  * ARM needs to avoid the 32-bit padding at the end, for consistency
  38.  * between EABI and OABI 
  39.  */
  40. #ifndef ARCH_PACK_STATFS64
  41. #define ARCH_PACK_STATFS64
  42. #endif
  43.  
  44. struct statfs64 {
  45.     __statfs_word f_type;
  46.     __statfs_word f_bsize;
  47.     __u64 f_blocks;
  48.     __u64 f_bfree;
  49.     __u64 f_bavail;
  50.     __u64 f_files;
  51.     __u64 f_ffree;
  52.     __kernel_fsid_t f_fsid;
  53.     __statfs_word f_namelen;
  54.     __statfs_word f_frsize;
  55.     __statfs_word f_spare[5];
  56. } ARCH_PACK_STATFS64;
  57.  
  58. /* 
  59.  * IA64 and x86_64 need to avoid the 32-bit padding at the end,
  60.  * to be compatible with the i386 ABI
  61.  */
  62. #ifndef ARCH_PACK_COMPAT_STATFS64
  63. #define ARCH_PACK_COMPAT_STATFS64
  64. #endif
  65.  
  66. struct compat_statfs64 {
  67.     __u32 f_type;
  68.     __u32 f_bsize;
  69.     __u64 f_blocks;
  70.     __u64 f_bfree;
  71.     __u64 f_bavail;
  72.     __u64 f_files;
  73.     __u64 f_ffree;
  74.     __kernel_fsid_t f_fsid;
  75.     __u32 f_namelen;
  76.     __u32 f_frsize;
  77.     __u32 f_spare[5];
  78. } ARCH_PACK_COMPAT_STATFS64;
  79.  
  80. #endif
  81.